package com.qfedu.edu.constance;

/**
 * @author xiaobobo
 * @title: RedisConstance
 * @projectName seckill-fy-2401-parent
 * @description: TODO
 * @date 2024/11/6  15:51
 */
public class RedisConstance {

    //产品库存的前缀
    private static final String PRO_STOCK_PREFIX = "pro:stock:";

    //用户购买商品的状态前缀
    private static final String BUY_STATUS_PREFIX = "buy:status:";

    //放行人数的计数前缀
    private static final String BUY_COUNT_PREFIX = "buy:count:";

    //减库存的前缀
    private static final String STOCK_REDUCE_PREFIX = "stock:reduce:";

    //订单支付的前缀
    private static final String PAY_STATUS_PREFIX = "pay:status:";

    public static String getPayStatusPrefix() {
        return PAY_STATUS_PREFIX;
    }

    //订单的前缀
    //private static final String ORDER_PREFIX = "order:";

    //商品信息存储到Redis中
    private static final String PRO_INFO_PREFIX = "pro:info:";

    public static String getProInfoPrefix() {
        return PRO_INFO_PREFIX;
    }

//    public static String getOrderPrefix() {
//        return ORDER_PREFIX;
//    }

    public static String getStockReducePrefix() {
        return STOCK_REDUCE_PREFIX;
    }

    public static String getBuyCountPrefix() {
        return BUY_COUNT_PREFIX;
    }

    public static String getBuyStatusPrefix() {
        return BUY_STATUS_PREFIX;
    }

    public static String getProStockPrefix() {
        return PRO_STOCK_PREFIX;
    }
}
